/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package mygame.model;

import com.thoughtworks.xstream.annotations.XStreamAlias;
import java.util.List;

/**
 * Node wrapper class for Xstream to help to instantiate 
 * Node object into the game.
 * GameNode can contanins childs that are the same type
 *
 * @author xwgou
 */

@XStreamAlias("node")
public class GameNode {
    public static enum TYPE {NODE, GEOMETRY_BOX};
    
    @XStreamAlias("type")
    private TYPE type;
    
    @XStreamAlias("name")
    private String name;
    
    @XStreamAlias("model")
    private String model;
    
    @XStreamAlias("material")
    private String material;
    
    private GameTexture texture;
    
    @XStreamAlias("translation")
    private float[] translation;
    
    @XStreamAlias("size")
    private float[] size;
    
    @XStreamAlias("rotation")
    private float[] rotation;
    
    @XStreamAlias("scale")
    private float[] scale;
    
    @XStreamAlias("move")
    private float[] move;
    
    // for meshes
    @XStreamAlias("center")
    private float[] center;
    
    @XStreamAlias("childs")
    private List<GameNode> childs;

    public List<GameNode> getChilds() {
        return childs;
    }

    public void setChilds(List<GameNode> childs) {
        this.childs = childs;
    }

    public String getMaterial() {
        return material;
    }

    public void setMaterial(String material) {
        this.material = material;
    }

    public String getModel() {
        return model;
    }

    public void setModel(String model) {
        this.model = model;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public float[] getRotation() {
        return rotation;
    }

    public void setRotation(float[] rotation) {
        this.rotation = rotation;
    }

    public float[] getScale() {
        return scale;
    }

    public void setScale(float[] scale) {
        this.scale = scale;
    }

    public GameTexture getTexture() {
        return texture;
    }

    public void setTexture(GameTexture texture) {
        this.texture = texture;
    }

    public float[] getTranslation() {
        return translation;
    }

    public void setTranslation(float[] translation) {
        this.translation = translation;
    }

    public TYPE getType() {
        return type;
    }

    public void setType(TYPE type) {
        this.type = type;
    }

    public float[] getSize() {
        return size;
    }

    public void setSize(float[] size) {
        this.size = size;
    }

    public float[] getCenter() {
        return center;
    }

    public void setCenter(float[] center) {
        this.center = center;
    }

    public float[] getMove() {
        return move;
    }

    public void setMove(float[] move) {
        this.move = move;
    }
    
}
